{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "my_str = 'hello world!'"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "str"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "type(my_str)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "str(object='') -> str\n",
      "str(bytes_or_buffer[, encoding[, errors]]) -> str\n",
      "\n",
      "Create a new string object from the given object. If encoding or\n",
      "errors is specified, then the object must expose a data buffer\n",
      "that will be decoded using the given encoding and error handler.\n",
      "Otherwise, returns the result of object.__str__() (if defined)\n",
      "or repr(object).\n",
      "encoding defaults to sys.getdefaultencoding().\n",
      "errors defaults to 'strict'.\n"
     ]
    }
   ],
   "source": [
    "print(my_str.__doc__)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "['__repr__',\n",
       " '__hash__',\n",
       " '__str__',\n",
       " '__getattribute__',\n",
       " '__lt__',\n",
       " '__le__',\n",
       " '__eq__',\n",
       " '__ne__',\n",
       " '__gt__',\n",
       " '__ge__',\n",
       " '__iter__',\n",
       " '__mod__',\n",
       " '__rmod__',\n",
       " '__len__',\n",
       " '__getitem__',\n",
       " '__add__',\n",
       " '__mul__',\n",
       " '__rmul__',\n",
       " '__contains__',\n",
       " '__new__',\n",
       " 'encode',\n",
       " 'replace',\n",
       " 'split',\n",
       " 'rsplit',\n",
       " 'join',\n",
       " 'capitalize',\n",
       " 'casefold',\n",
       " 'title',\n",
       " 'center',\n",
       " 'count',\n",
       " 'expandtabs',\n",
       " 'find',\n",
       " 'partition',\n",
       " 'index',\n",
       " 'ljust',\n",
       " 'lower',\n",
       " 'lstrip',\n",
       " 'rfind',\n",
       " 'rindex',\n",
       " 'rjust',\n",
       " 'rstrip',\n",
       " 'rpartition',\n",
       " 'splitlines',\n",
       " 'strip',\n",
       " 'swapcase',\n",
       " 'translate',\n",
       " 'upper',\n",
       " 'startswith',\n",
       " 'endswith',\n",
       " 'isascii',\n",
       " 'islower',\n",
       " 'isupper',\n",
       " 'istitle',\n",
       " 'isspace',\n",
       " 'isdecimal',\n",
       " 'isdigit',\n",
       " 'isnumeric',\n",
       " 'isalpha',\n",
       " 'isalnum',\n",
       " 'isidentifier',\n",
       " 'isprintable',\n",
       " 'zfill',\n",
       " 'format',\n",
       " 'format_map',\n",
       " '__format__',\n",
       " 'maketrans',\n",
       " '__sizeof__',\n",
       " '__getnewargs__',\n",
       " '__doc__',\n",
       " '__setattr__',\n",
       " '__delattr__',\n",
       " '__init__',\n",
       " '__reduce_ex__',\n",
       " '__reduce__',\n",
       " '__subclasshook__',\n",
       " '__init_subclass__',\n",
       " '__dir__',\n",
       " '__class__']"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "my_str.__dir__()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'Hello world!'"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "my_str.capitalize()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'HELLO WORLD!'"
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "my_str.upper()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'helloworld!'"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "my_str.replace(' ', '')"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.1"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
